generated from storyprotocol/solidity-template
-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
IPOrg refactor for creation & registration #168
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
leeren
force-pushed
the
iporg-refactor
branch
from
November 13, 2023 11:07
9b87bf7
to
102f51b
Compare
leeren
force-pushed
the
iporg-refactor
branch
from
November 15, 2023 03:24
7f2150a
to
e8f773e
Compare
Ramarti
approved these changes
Nov 15, 2023
This was referenced Nov 28, 2023
Ramarti
added a commit
that referenced
this pull request
Dec 8, 2023
* Adds core authorization and attribution to the GIPR (#157) * Adds core authorization and attribution to the GIPR * Fixes accidental old code merge * Fixes IPAssetOrg Test * Added callpath from SPG to ModuleRegistry, refactor Relationship module (#160) * story protocol entrypoint * remove event emitter * refactor IPOrg * fix * register ipOrg * wip * module registry basic functionality * remove leftover test * module registry routing to modules * add module registyr to SPG * relationship registry * connected SPG with protocol module * config types * test remove relationship * relationship setting * comments and fixes * unify module registry events * refactor selfParams into moduleParams * view methods in IPAssetRegistry --------- Co-authored-by: Raul <[email protected]> * refactor_tests (#163) Authored-by: Raul <[email protected]> * Implementation of Hooks Architecture with Asynchronous and Synchronous Base Hooks (#161) * Implementation of Hooks Architecture with Async and Sync Base Hooks * Add TokenGatedHook Contract for NFT Ownership Verification (#167) * Add TokenGatedHook Contract for NFT Ownership Verification * Enhance HookRegistry to Support Separate Config (#171) * Refactor HookRegistry to support multiple config domain Introduce `registryKey` to separate different config domains. And Integrating BaseModule and Hooks * Upgrade openzeppline to 4.9.3 (#173) * list all files in workspace * upgrade openzepplin to 4.9.3 * IPOrg refactor for creation & registration (#168) * Refactors IP Org * Adds scaffolding for metadata rendering and ip asset creation * Modularizes IP Org transfers and adds metadata wrapping * Adds IPOrg registration * Fixes stack too deep * Adds back hookregistrykey * Fixes testing * Finalizes registration module (adds necessary FEs needed for SPG integration) * Fix transfer bug * Refactor licensing (#170) * configure ipOrg license * terms repository, framework config * wip * introducing hooks for terms * short string helpers * terms hook * licensing module, config ipOrg licensing framework * cleanup * IPA goes into IPAsset library * deleted old interfaces * delete old contracts * refactored configuration to be purely terms based, testing creating licenses * refactor TermsConfig, added FixedSet * create root license * minting LNFT * refactor licensing term libs * fix test * refactor to account for enshrined share alike * refactored IPA_LICENSE and SUBLICENSE_OF back into the licensing module * simplified terms data * add comments: * more comments * fixed comments and added access control to license registry * import order * todo hook key providing * remove hardhat tests * fixing compilation errors * introducing ipa registration module * temporally remove tests --------- Co-authored-by: Raul <[email protected]> * Refactor Access Control in HookRegistry Contract (#175) * Refactor hook registry access control by IPOrg owner * Add hooksRegistry() function to modules * Iporg types and tests (#177) * Adds testing for registration module * Adds scaffolding for custom ipAssetTypes * Remove old comments * Adding support register IP Asset with user defined mediaURL (#181) * License activation (#176) * hookity hook * hook ouuuut * lol * wip testing * simplify licensing * WIP * fixes * more fixes * wip * fix tests * typo * separated termrepository from accesscontrol * Update contracts/modules/licensing/LicensingModule.sol Co-authored-by: kingster-will <[email protected]> --------- Co-authored-by: Raul <[email protected]> Co-authored-by: kingster-will <[email protected]> * Deployment scripts for Alpha release on Sepolia (#178) * deploy stroy protocol contracts to Sepolia * redeploy with latest change * redeploy for with PR#181 * redeploy for with active license PR#176 * Update script/foundry/deployment/Main.s.sol * Update script/foundry/deployment/Main.s.sol --------- Co-authored-by: Ramarti <[email protected]> * remove logs and add Multicall to StoryProtocol.sol (#186) Co-authored-by: Raul <[email protected]> * Fixes IP asset types (#179) * Address a series issues of event (#187) * Fix following issues - remove underscore postfix from event field - rename event field `ipaId` to `ipAssetId` - fix wrong `owner` in IPOrgRegistered event - add ipAssetTypes into IPOrgRegistered event - remove `indexed` from string or array event fields --------- Co-authored-by: Ramarti <[email protected]> * Add E2E tests for Alpha (#189) * Implementing Dual Licensing Model for Core and Extended Functionalities (#190) * Apply dual licenses to source code, BUSL and MIT * Connected IPOrg asset types to relationship module and removed IP Asset Type (#188) * ip org types and elimination of ip asset type * fixing tests * refactor registration tests * fixed existing tests * test iporg * test protocol relationship types configuration * test relationship setting * remove unused struct * removed commented out code * refactor tokenURI * fix --------- Co-authored-by: Raul <[email protected]> * Temporarily Comment Out Unused Modules for Alpha Release Preparation (#191) * Temporarily Comment Out Unused Modules for Alpha Release Preparation We have temporarily commented out the Collect and Royalty modules to streamline the codebase for the alpha release. These changes are not permanent and these modules will be reintroduced in future releases. * Introduce solidity-docgen in the project for generating documents (#202) Authored-by: Samuel Zhou * cleanup deployment broadcast directory (#197) * Adds detailed contract documentation (#203) * Adds detailed documentation for major contracts * Prevent complaining about max line * Update Deployment Script and Re-deploy Protocol Contracts (#204) * Update deployment script and Re-deploy protocol * Test access control (#206) * test access control * test access controlled --------- Co-authored-by: Raul <[email protected]> * Remove 'indexed' from string relType events * remove underscore postfix from registration events * License refactor to simplify and fit Protocol IP License (#214) * licensing framework repo * config iporg * WIP * moved some verification to LicenseRegistry * simplify libs * wip * addReciprocal is in LicenseRegistry for efficiency, non reciprocal has implementation, uncommented the rest * wip testing licensing * test create license * test other happy paths and fixes * some comments * whitespace * made default revoker configurable --------- Co-authored-by: Raul <[email protected]> * Increase Code Lines Coverage (Unit + Integration) (#216) * Remove 'indexed' from string relType events * Module registry events test * Add make coverage script * Add more access control tests * Add more IPOrg (controller) tests * fix: IPOrgTransferred event emit, cache record.owner for prevOwner event arg * Add more test for IPOrg controller Coverage except internal functions and `initialize` for upgradable. Need to use harness for internal functions. * Add basic tests for FixedSet util * fix: FixedSet.UintSet indexOf argument signature * Add integration tests to full line coverage * Add coverage instruction * Updated tests for e2e and modules * Contract bug fix & comment nit * lcov update * Fix licensing module test cases * Separate tests & remove lcov file * deployment script with licensing module and sepolia (#224) Co-authored-by: Raul <[email protected]> * Emit license data (#228) * emit License data and gas saving in reciprocals * deployment --------- Co-authored-by: Raul <[email protected]> * Alpha agreement (#229) * BUSL changed to alpha agreement * verified deployment --------- Co-authored-by: Raul <[email protected]> * allow param def empty array * fix empty config param array ipOrg * Introducing Polygon Token Async Hook and Integration Async Hook with BaseModule (#230) * Introduce PolygonTokenHook and integrate Async hook with BaseMoudle - A new contract PolygonTokenHook is introduced. - The BaseModule contract is updated to support the execution of asynchronous hooks. - The type of hook (synchronous or asynchronous) is determined by the first two bits of the hook address. * Support Licensing Framework default values (#233) * bitmask * wip refactor derivatives to proper options * wip, hitting stack too deep * wip fixed stack too deep, fixing tests * fix bitmask * fix, test, remove logs, fix internal to pure --------- Co-authored-by: Raul <[email protected]> * refactor to SPUML, comments * deployment * fix dep script * Adds authorization (#227) Adds new authorization logic around the module registry * Fix events (#237) * fix emission for ipOrg config * deployed fix events --------- Co-authored-by: Raul <[email protected]> * Add license metadata (#238) * wip * wip * fix emission for ipOrg config * metadata * event for indexing * Update test/foundry/lib/BitMask.t.sol * Update test/foundry/lib/BitMask.t.sol * fix * deployment --------- Co-authored-by: Raul <[email protected]> * Improved Unit & Integration Test (#231) * Remove 'indexed' from string relType events * Module registry events test * Add make coverage script * Add more access control tests * Add more IPOrg (controller) tests * fix: IPOrgTransferred event emit, cache record.owner for prevOwner event arg * Add more test for IPOrg controller Coverage except internal functions and `initialize` for upgradable. Need to use harness for internal functions. * Add basic tests for FixedSet util * fix: FixedSet.UintSet indexOf argument signature * Add integration tests to full line coverage * Add coverage instruction * Updated tests for e2e and modules * Contract bug fix & comment nit * lcov update * Fix licensing module test cases * Separate tests & remove lcov file * Update integration tests * Small fixes for contracts & interfaces * Update e2e and module tests & comment out unready fn * Updated tests * More integration tests * Fix param comment * Add integration tests, fix unit tests, fix contract bugs * Remove commented out function * Update LicensingModule.Licensing.t.sol * Update LicensingModule.Config.t.sol * Link existing license to ipa on creation (#239) * fix emission for ipOrg config * added optional ipa_param * link ipa to license on creation * deployment --------- Co-authored-by: Raul <[email protected]> * Format and commenting refactor (#241) * Polishes comments and standardizes formatting * Fixes more formatting * Adds more comments * Fixes minor doc error * Comment licensing (#240) * licensing lib commented * framework repo * comment licensing module * fixes * lint --------- Co-authored-by: Raul <[email protected]> * Small test coverages (#242) * Add more nit tests for coverage * Remove unused lib * Remove library * Fix nit testcase * Readme (#243) * readme * renamed mvp folder to legacy * fix image --------- Co-authored-by: Raul <[email protected]> * Update README.md * Update README.md * changeset * changelog * Update README.md --------- Co-authored-by: Leeren <[email protected]> Co-authored-by: Raul <[email protected]> Co-authored-by: kingster-will <[email protected]> Co-authored-by: Samuel Zhou <[email protected]> Co-authored-by: Jongwon Park <[email protected]> Co-authored-by: Kingster <[email protected]>
Ramarti
added a commit
that referenced
this pull request
Dec 8, 2023
* Adds core authorization and attribution to the GIPR (#157) * Adds core authorization and attribution to the GIPR * Fixes accidental old code merge * Fixes IPAssetOrg Test * Added callpath from SPG to ModuleRegistry, refactor Relationship module (#160) * story protocol entrypoint * remove event emitter * refactor IPOrg * fix * register ipOrg * wip * module registry basic functionality * remove leftover test * module registry routing to modules * add module registyr to SPG * relationship registry * connected SPG with protocol module * config types * test remove relationship * relationship setting * comments and fixes * unify module registry events * refactor selfParams into moduleParams * view methods in IPAssetRegistry --------- Co-authored-by: Raul <[email protected]> * refactor_tests (#163) Authored-by: Raul <[email protected]> * Implementation of Hooks Architecture with Asynchronous and Synchronous Base Hooks (#161) * Implementation of Hooks Architecture with Async and Sync Base Hooks * Add TokenGatedHook Contract for NFT Ownership Verification (#167) * Add TokenGatedHook Contract for NFT Ownership Verification * Enhance HookRegistry to Support Separate Config (#171) * Refactor HookRegistry to support multiple config domain Introduce `registryKey` to separate different config domains. And Integrating BaseModule and Hooks * Upgrade openzeppline to 4.9.3 (#173) * list all files in workspace * upgrade openzepplin to 4.9.3 * IPOrg refactor for creation & registration (#168) * Refactors IP Org * Adds scaffolding for metadata rendering and ip asset creation * Modularizes IP Org transfers and adds metadata wrapping * Adds IPOrg registration * Fixes stack too deep * Adds back hookregistrykey * Fixes testing * Finalizes registration module (adds necessary FEs needed for SPG integration) * Fix transfer bug * Refactor licensing (#170) * configure ipOrg license * terms repository, framework config * wip * introducing hooks for terms * short string helpers * terms hook * licensing module, config ipOrg licensing framework * cleanup * IPA goes into IPAsset library * deleted old interfaces * delete old contracts * refactored configuration to be purely terms based, testing creating licenses * refactor TermsConfig, added FixedSet * create root license * minting LNFT * refactor licensing term libs * fix test * refactor to account for enshrined share alike * refactored IPA_LICENSE and SUBLICENSE_OF back into the licensing module * simplified terms data * add comments: * more comments * fixed comments and added access control to license registry * import order * todo hook key providing * remove hardhat tests * fixing compilation errors * introducing ipa registration module * temporally remove tests --------- Co-authored-by: Raul <[email protected]> * Refactor Access Control in HookRegistry Contract (#175) * Refactor hook registry access control by IPOrg owner * Add hooksRegistry() function to modules * Iporg types and tests (#177) * Adds testing for registration module * Adds scaffolding for custom ipAssetTypes * Remove old comments * Adding support register IP Asset with user defined mediaURL (#181) * License activation (#176) * hookity hook * hook ouuuut * lol * wip testing * simplify licensing * WIP * fixes * more fixes * wip * fix tests * typo * separated termrepository from accesscontrol * Update contracts/modules/licensing/LicensingModule.sol Co-authored-by: kingster-will <[email protected]> --------- Co-authored-by: Raul <[email protected]> Co-authored-by: kingster-will <[email protected]> * Deployment scripts for Alpha release on Sepolia (#178) * deploy stroy protocol contracts to Sepolia * redeploy with latest change * redeploy for with PR#181 * redeploy for with active license PR#176 * Update script/foundry/deployment/Main.s.sol * Update script/foundry/deployment/Main.s.sol --------- Co-authored-by: Ramarti <[email protected]> * remove logs and add Multicall to StoryProtocol.sol (#186) Co-authored-by: Raul <[email protected]> * Fixes IP asset types (#179) * Address a series issues of event (#187) * Fix following issues - remove underscore postfix from event field - rename event field `ipaId` to `ipAssetId` - fix wrong `owner` in IPOrgRegistered event - add ipAssetTypes into IPOrgRegistered event - remove `indexed` from string or array event fields --------- Co-authored-by: Ramarti <[email protected]> * Add E2E tests for Alpha (#189) * Implementing Dual Licensing Model for Core and Extended Functionalities (#190) * Apply dual licenses to source code, BUSL and MIT * Connected IPOrg asset types to relationship module and removed IP Asset Type (#188) * ip org types and elimination of ip asset type * fixing tests * refactor registration tests * fixed existing tests * test iporg * test protocol relationship types configuration * test relationship setting * remove unused struct * removed commented out code * refactor tokenURI * fix --------- Co-authored-by: Raul <[email protected]> * Temporarily Comment Out Unused Modules for Alpha Release Preparation (#191) * Temporarily Comment Out Unused Modules for Alpha Release Preparation We have temporarily commented out the Collect and Royalty modules to streamline the codebase for the alpha release. These changes are not permanent and these modules will be reintroduced in future releases. * Introduce solidity-docgen in the project for generating documents (#202) Authored-by: Samuel Zhou * cleanup deployment broadcast directory (#197) * Adds detailed contract documentation (#203) * Adds detailed documentation for major contracts * Prevent complaining about max line * Update Deployment Script and Re-deploy Protocol Contracts (#204) * Update deployment script and Re-deploy protocol * Test access control (#206) * test access control * test access controlled --------- Co-authored-by: Raul <[email protected]> * Remove 'indexed' from string relType events * remove underscore postfix from registration events * License refactor to simplify and fit Protocol IP License (#214) * licensing framework repo * config iporg * WIP * moved some verification to LicenseRegistry * simplify libs * wip * addReciprocal is in LicenseRegistry for efficiency, non reciprocal has implementation, uncommented the rest * wip testing licensing * test create license * test other happy paths and fixes * some comments * whitespace * made default revoker configurable --------- Co-authored-by: Raul <[email protected]> * Increase Code Lines Coverage (Unit + Integration) (#216) * Remove 'indexed' from string relType events * Module registry events test * Add make coverage script * Add more access control tests * Add more IPOrg (controller) tests * fix: IPOrgTransferred event emit, cache record.owner for prevOwner event arg * Add more test for IPOrg controller Coverage except internal functions and `initialize` for upgradable. Need to use harness for internal functions. * Add basic tests for FixedSet util * fix: FixedSet.UintSet indexOf argument signature * Add integration tests to full line coverage * Add coverage instruction * Updated tests for e2e and modules * Contract bug fix & comment nit * lcov update * Fix licensing module test cases * Separate tests & remove lcov file * deployment script with licensing module and sepolia (#224) Co-authored-by: Raul <[email protected]> * Emit license data (#228) * emit License data and gas saving in reciprocals * deployment --------- Co-authored-by: Raul <[email protected]> * Alpha agreement (#229) * BUSL changed to alpha agreement * verified deployment --------- Co-authored-by: Raul <[email protected]> * allow param def empty array * fix empty config param array ipOrg * Introducing Polygon Token Async Hook and Integration Async Hook with BaseModule (#230) * Introduce PolygonTokenHook and integrate Async hook with BaseMoudle - A new contract PolygonTokenHook is introduced. - The BaseModule contract is updated to support the execution of asynchronous hooks. - The type of hook (synchronous or asynchronous) is determined by the first two bits of the hook address. * Support Licensing Framework default values (#233) * bitmask * wip refactor derivatives to proper options * wip, hitting stack too deep * wip fixed stack too deep, fixing tests * fix bitmask * fix, test, remove logs, fix internal to pure --------- Co-authored-by: Raul <[email protected]> * refactor to SPUML, comments * deployment * fix dep script * Adds authorization (#227) Adds new authorization logic around the module registry * Fix events (#237) * fix emission for ipOrg config * deployed fix events --------- Co-authored-by: Raul <[email protected]> * Add license metadata (#238) * wip * wip * fix emission for ipOrg config * metadata * event for indexing * Update test/foundry/lib/BitMask.t.sol * Update test/foundry/lib/BitMask.t.sol * fix * deployment --------- Co-authored-by: Raul <[email protected]> * Improved Unit & Integration Test (#231) * Remove 'indexed' from string relType events * Module registry events test * Add make coverage script * Add more access control tests * Add more IPOrg (controller) tests * fix: IPOrgTransferred event emit, cache record.owner for prevOwner event arg * Add more test for IPOrg controller Coverage except internal functions and `initialize` for upgradable. Need to use harness for internal functions. * Add basic tests for FixedSet util * fix: FixedSet.UintSet indexOf argument signature * Add integration tests to full line coverage * Add coverage instruction * Updated tests for e2e and modules * Contract bug fix & comment nit * lcov update * Fix licensing module test cases * Separate tests & remove lcov file * Update integration tests * Small fixes for contracts & interfaces * Update e2e and module tests & comment out unready fn * Updated tests * More integration tests * Fix param comment * Add integration tests, fix unit tests, fix contract bugs * Remove commented out function * Update LicensingModule.Licensing.t.sol * Update LicensingModule.Config.t.sol * Link existing license to ipa on creation (#239) * fix emission for ipOrg config * added optional ipa_param * link ipa to license on creation * deployment --------- Co-authored-by: Raul <[email protected]> * Format and commenting refactor (#241) * Polishes comments and standardizes formatting * Fixes more formatting * Adds more comments * Fixes minor doc error * Comment licensing (#240) * licensing lib commented * framework repo * comment licensing module * fixes * lint --------- Co-authored-by: Raul <[email protected]> * Small test coverages (#242) * Add more nit tests for coverage * Remove unused lib * Remove library * Fix nit testcase * Readme (#243) * readme * renamed mvp folder to legacy * fix image --------- Co-authored-by: Raul <[email protected]> * Update README.md * Update README.md * changeset * changelog * Update README.md * Comments (#246) * underscore bitmask lib * comments * comments and formatting * licensing underscore * busl --------- Co-authored-by: Raul <[email protected]> --------- Co-authored-by: Leeren <[email protected]> Co-authored-by: Raul <[email protected]> Co-authored-by: kingster-will <[email protected]> Co-authored-by: Samuel Zhou <[email protected]> Co-authored-by: Jongwon Park <[email protected]> Co-authored-by: Kingster <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Core Changes: